package com.droidpark.android.tools.bar;

import android.app.Activity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;

public class DroidBarActivity extends Activity {
    
	private DroidBar droidBar;
	
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        initDroidBar();
    }
    
    private void initDroidBar() {
    	
    	droidBar = (DroidBar) findViewById(R.id.droidBar);
    	droidBar.setTitle("DroidPark");
    	droidBar.setAppIcon(android.R.drawable.ic_menu_mylocation);
    	
    	droidBar.addActionButton(android.R.drawable.ic_menu_compass, new OnClickListener() {
			public void onClick(View v) {
				Log.i("ActionBar", "Compass Clicked!");
			}
		});
    	
    	droidBar.addActionButton(android.R.drawable.ic_menu_search, new OnClickListener() {
			public void onClick(View v) {
				Log.i("ActionBar", "Search Clicked!");
			}
		});
    }
}